Detect Macintosh vs Windows

This page contains an embedded reference movie named "macwin.mov" that plays either "mac.mov" or "win.mov" depending on the viewer's operating system.



The reference movie was created using Peter Hoddie's XMLtoRefMovie tool using the following text:

<qtrefmovie>
  <refmovie src="win.mov" priority="high">   <version selector="cput" value="0x69000000" mask="0xff000000" />  </refmovie>  
  <refmovie src="mac.mov" priority="low"/>  
</qtrefmovie>

To use this in your Web page:

  1. Copy the text above into a text editor.
  2. Change the SRC of the first refmovie to the URL of a movie to play on Windows.
  3. Change the SRC of the second refmovie to the URL of a movie to play on Macs.
  4. Save with the file extension .qtrm.
  5. Drag onto XMLtoRefMovie.
  6. Embed the resulting reference movie in your Web page.


Technical note:
This checks the cpu type (cput) to see if it starts with "i" (i486, i586, etc.), by masking out the lower 3 bytes (ff000000) and looking for "i" in the high byte (69000000). Requires version 0.94 or later of XMLtoRefMovie (the mask and value attributes were swapped in earlier versions).